/**
 * 用来保存全局常量
 * 模型服务器配置
 */
let BaseURL = process.env.VUE_APP_bimBaseUrl
let ModelConfig
let EngineConfig


// switch (process.env.NODE_ENV) {
//   // 开发环境
//   case 'development':

//     BaseURL = 'https://engine.everybim.net/';

//     //模型列表 模型服务器配置
//     ModelConfig = {
//         serverIp : 'https://model.everybim.net',
//         appKey : 'YHeLIehn9wNacNT2YZ08ggqM3HhldCF2X1Ng',
//         appSecret : '818137e741bf3ab769c9266afd42165633f11f3137bd632b62fc70e56608b943'
//     };

//     //示例模型 模型服务器配置
//     EngineConfig ={
//         serverIp : 'https://engine.everybim.net',
//         appKey :'hw24HWfcBg3sc3PQZUTIRc5OervojWrbTHvK',
//         appSecret : '9645a8210f85867d1d2248959a42b34fea4117513c9c4c98a1ce4aae6cef3b52'   
//     }
//     break
// // 生产环境
//   case 'production':

//     BaseURL = 'https://engine.everybim.net/';
    
//     //模型列表 模型服务器配置
//     ModelConfig = {
//       serverIp : 'https://model.everybim.net', 
//       appKey : 'YHeLIehn9wNacNT2YZ08ggqM3HhldCF2X1Ng',
//       appSecret : '818137e741bf3ab769c9266afd42165633f11f3137bd632b62fc70e56608b943'
//     };

//     //示例模型 模型服务器配置
//     EngineConfig ={
//         serverIp : 'https://engine.everybim.net',
//         appKey :'hw24HWfcBg3sc3PQZUTIRc5OervojWrbTHvK',
//         appSecret : '9645a8210f85867d1d2248959a42b34fea4117513c9c4c98a1ce4aae6cef3b52'   
//     }
//   break
// }

//打包 server 置空

//let server = 'http://192.168.1.64:3102';
// let server = 'https://model.everybim.net';
let server = BaseURL
let APIURL = `${server}/api/v1/models`;
let COMAPIURL = `${server}/api/v1`

// df本地服务器测试用数据
ModelConfig = {
  serverIp: server,
  appKey: process.env.VUE_APP_bimAppKey,
  appSecret: process.env.VUE_APP_bimAppSecret
}

module.exports = {
  baseURL: BaseURL,
  ApiURL: APIURL,
  comApiUrl: COMAPIURL,
  modelConfig: ModelConfig,
  engineConfig: EngineConfig,
}